Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Session: Removes Global Session Token on GW request if we can't resolve the scoped session t… #2975

Merged
merged 3 commits into from
Jan 14, 2022

Conversation

asketagarwal
Copy link
Contributor

The .NET SDK is sending the global session token if it does not have the partition key range id in the session token cache. This can cause the request to fail from the header being too large. Once the session token is added to the session token cache it is properly filtered for future requests. This impacts both point operations and query for the first operation going to that partition key range id.

Solution:
If there is no session token for the specificied partition key range id or the parent range ids then no session token should be sent because it is the first request to that partition range id.

Closing issues

closes #2969

Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please follow the required format: "[Internal] Category: (Adds|Fixes|Refactors|Removes) Description"

Internal should be used for PRs that have no customer impact. This flag is used to help generate the changelog to know which PRs should be included. Examples:
Diagnostics: Adds GetElapsedClientLatency to CosmosDiagnostics
PartitionKey: Fixes null reference when using default(PartitionKey)
[v4] Client Encryption: Refactors code to external project
[Internal] Query: Adds code generator for CosmosNumbers for easy additions in the future.

@asketagarwal asketagarwal changed the title Session: Avoid Global Session Token on GW if we can't resolve scoped session t… Session: Removes Global Session Token on GW request if we can't resolve the scoped session t… Jan 10, 2022
@j82w j82w enabled auto-merge (squash) January 14, 2022 20:45
@j82w j82w merged commit 67cbd89 into master Jan 14, 2022
@j82w j82w deleted the users/askagarw/globalsessiontokenfix branch January 14, 2022 21:20
Copy link
Member

@FabianMeiswinkel FabianMeiswinkel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

SDK sends full session token first time going to new partition
5 participants